package base;

/**
 * @Author Miku
 * @Create 2021/2/2 17:19
 * Java类型强制转换
 */
public class Demo01 {
    public static void main(String[] args) {
        int i = 128;
        byte b = (byte) i;
        double d = i;

        System.out.println(i);
        System.out.println(b);
        System.out.println(d);

        System.out.println("=======================");
        System.out.println((int) 12.3);
        System.out.println((int) -213.99f);

        System.out.println("=======================");
        char c = 'a';
        int a = c + 1;
        System.out.println(a);
        System.out.println((char) a);
    }
}
